package spring.demo.listener;

import org.springframework.context.ApplicationEvent;
import org.springframework.stereotype.Component;

@Component
public class MyEnvent extends ApplicationEvent {

    private String name;
    Object source;

    /**
     * Create a new ApplicationEvent.
     *
     * @param source the object on which the event initially occurred (never {@code null})
     */
    public MyEnvent(Object source) {
        super(source);
        this.source = source;
    }
}
